﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NeuroSpeech.XamlExtensions;
using System.ComponentModel.Composition;
using System.ComponentModel.Composition.Hosting;

namespace NeuroSpeech.XamlGenerator.Code.Writers.Converters
{
    public class ConverterStore
    {

        [Import]
        public DefaultConverter[] Converters;


        private static ConverterStore _Store = null;
        public static ConverterStore Default {
            get {
                if (_Store == null)
                {
                    _Store = new ConverterStore();
                    var composer = new CompositionContainer();
                    composer.ComposeParts(_Store);
                }
                return _Store;
            }
        }

    }
}
